package org.jsbd.boss.action;


import javax.servlet.http.HttpServletResponse;

import org.jsbd.boss.common.ResponseUtils;
import org.jsbd.boss.domian.SmallSatelliteNum;
import org.jsbd.boss.service.ISoContentService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.alibaba.fastjson.JSONObject;

@Controller
@RequestMapping("/so/content")
public class SoContentController {
	public static final Logger LOGGER = LoggerFactory.getLogger(SoContentController.class);

	@Autowired
	private ISoContentService soContentService;
	
	@RequestMapping(value = "get")
	@ResponseBody
	public void getSoContent(HttpServletResponse resp) throws Exception {
		String data=soContentService.getSoContent();
		JSONObject json=new JSONObject();
		json.put("resultCode", 1);
		json.put("data", data);
		ResponseUtils.renderJson(resp, json.toJSONString());
	}

}
